<% @item = @team %>
<%= render :partial => "shared/admin_box" %>

<h3><%= link_to "#{@team.ministry.department.name}",
 				:controller => 'departments',
				:action => 'show',
				:id => @team.ministry.department.id %> Department :: <%= link_to "#{@team.ministry.name}",
 															:controller => 'ministries',
															:action => 'show', :id => @team.ministry.id %> Ministry</h3>
<h2>Team Name: <%= @team.name %></h2>

<fieldset>
	<legend>
		<strong>Team Info</strong>
	</legend>
<table border="0" cellspacing="0" cellpadding="2" valign="top">
	<tr>
		<td>
			<% if @team.responsible_person_title.empty? %>
				<b>No Title Recorded:</b>
			<% else %>
				<b><%= @team.responsible_person_title %>:</b>
			<% end %>
		</td>
		<td>
			<% if @team.responsible_person.nil? %>
			None assigned
			<% else %>
			<%= @team.responsible_person.full_name rescue nil %>
			<% end %>
		</td>
	</tr>
	<tr>
		<td><b>Purpose:</b></td>
		<td><%= @team.purpose %></td>
	</tr>
	<tr>
		<td><b>Win:</b></td>
		<td><%= @team.win %></td>
	</tr>
</table>


<%= link_to 'Edit', :action => 'edit', :id => @team %> |
<%= link_to 'Manage Ministries', :controller => 'ministries', :action => 'manage' %>

</fieldset>


<br><br>
<div id="team-tabs" style="float:none;clear:both;width:100%;">
	<%= render :partial => "team_tabs", :locals => {:team_id => @team} %>	
		<span id='progress' style='display:none;'><img src='/images/working.gif'></span>
</div>

<div id="tabs-area" style="background-color:#F5F5F5;float:none; clear:both;">
	<%= render :partial => "#{session[:team_partial]}", :locals => {:team => @team} %>
</div>

<% content_for :dashboard do %>
<div>
<strong><%= link_to_remote "Rotations",
 							:url => {:action => 'show_rotations_panel',
									:team => @team }%> | <%= link_to_remote "Roster", 
																			:url => {:action => 'show_roster_panel',
																			:team => @team} %></strong>
	<div id="dashboard-content">
		<%= render :partial => "rotations_panel", :locals => {:team => @team } %>
	</div>
		
</div>
<% end %>